package kr.hkit.powerjava.chapter10.Programming;

import java.util.Scanner;

public class PgMain {

	public static void main(String[] args) {
		
		Scanner input = new Scanner(System.in);

		System.out.print("학생의 수를 입력하시오: ");
		Average average = new Average(input.nextInt());

		average.setScores();
		System.out.printf("성적 평균은 %3.2f입니다.",average.makeAvg());
		
		System.out.printf("\n\n\n");
		boolean modeReservation = true;
		Reservation reserve = new Reservation();

		while (modeReservation) {
			System.out.print("좌석을 예약하시겠습니까? (1:예약 0:취소): ");
			if (reserve.input.nextInt() == 0) {
				modeReservation = false;
			} else {
				reserve.showReservation();
				reserve.selectseat();
			}
		}
	}
}
